package com.oujia.cloud.cloudcommon.dto.parm;

import com.oujia.cloud.cloudcommon.validator.group.AddGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.NotNull;

@ApiModel(value = "SearchQueryDTO", description = "查询消息记录")
@Data
public class SearchQueryDTO {

    @ApiModelProperty(value = "索引类型(不传入查询所有类型)")
    private String type;

    @ApiModelProperty(value = "是否联想",hidden = true)
    private Boolean isAssociation=false;

    @ApiModelProperty(value = "搜索关键字", required = true)
    @NotBlank(message = "搜索关键字不能为空", groups = {AddGroup.class})
    private String searchKey;
}
